/***************************************************************************
 *  Filename: logger.h
 *  Class: Logger
 *  
 *  Copyright 2012  Jacco van der Spek
 *  <jaccovdspek@gmail.com>
 *
 *  Copyright 2012  Mario Henrique Voorsluys
 *  <forcaeluz@gmail.com>
 *  
 ****************************************************************************/

/*
 *
 * This file is part of %ProjectName%.
 *
 *    %ProjectName% is free software: you can redistribute it and/or modify
 *    it under the terms of the GNU General Public License as published by
 *    the Free Software Foundation, either version 3 of the License, or
 *    (at your option) any later version.
 *
 *    %ProjectName% is distributed in the hope that it will be useful,
 *    but WITHOUT ANY WARRANTY; without even the implied warranty of
 *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *    GNU General Public License for more details.
 *
 *    You should have received a copy of the GNU General Public License
 *    along with %ProjectName%.  If not, see <http://www.gnu.org/licenses/>.
 */

#ifndef LOGGER_H
#define LOGGER_H

#include <QObject>
#include <QTextStream>
#include <QIODevice>
#include <QFile>
#include <QDateTime>
#include <QTime>
class Logger : public QObject
{
    Q_OBJECT
public:
    explicit Logger(QObject *parent = 0);
    
signals:
    
public slots:
    void setFileName(QString name);
    void logData(int time, float roll, float pitch, float yaw, float vx, float vy, float vz, qint32 altitude);
    void setDesires(float troll, float tpitch, float tyaw, float tgaz);
private:
    QTime generalTime;
    QString fileName;
    qint64 testStartTime;
    float roll;
    float pitch;
    float yaw;
    float gaz;
};

#endif // LOGGER_H
